import React, { useState } from 'react'
import { View,  Button, Radio, RadioGroup, Input, Label } from '@tarojs/components'
import './examine-result.scss'

function TestResult () {
  // 用考试结果
  const [userTestResult, setUserTestResult] = useState([
    { title: '性别'}, 
    { title: '是否有高血历史'},
    { title: '是否有充血性衰竭'},
    { title: '是否有糖尿病病史'},
    { title: '是否有中风'},
    { title: '是否有血管病变'},
  ])
  
  return (
    <View className="container">
      <View className="top-text">
        <View className="text-title">
        尊敬的先生/女士：
        </View>
        <View className="text-content">
        您好，您已完成了治疗评估测试，评分为<Label className="text-label">5分</Label>,根据评估测试结果,<Label className="text-label">推荐口服抗凝药物治疗;(华法林)</Label>
        </View>
      </View>
      {
        userTestResult.map((item, index) => (
          <View key={index} className="content-list">
            <View className="list-item">
              <View className="list-title">{index + 1}.{item.title}</View>
              <View className="list-result">
                <RadioGroup>
                  <Radio value="选中" >有</Radio>
                  <Radio  value="未选中" className="list-radio">没有</Radio>
                </RadioGroup>
              </View>
            </View> 
          </View>
        ))
      }
      <View className="sumbitBtn">
        <Button type="primary">提 交</Button>
      </View>
    </View>
  )
}

export default TestResult